<?php
/*
 * @Author: 李志刚
 * @CopyRight: 2020-2030 衡水山木枝技术服务有限公司
 * @Date: 2021-06-10 15:58:45
 * @Description: 供应商表
 * @LastEditors: 李志刚
 * @LastEditTime: 2021-09-17 08:26:17
 * @FilePath: /qingshanERP/database/migrations/qingshanerp/2021_06_10_155845_create_supplier.php
 */

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

class CreateSupplier extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('suppliers', function (Blueprint $table) {
            $table->id();
            $table->string('suppliername', 100)->comment('供应商名称');
            $table->string('refund_address_id', 100)->nullable()->comment('退货地址id');
            $table->string('name', 100)->nullable()->comment('发件人姓名');
            $table->string('phone', 100)->nullable()->comment('电话');
            $table->string('province', 100)->nullable()->comment('省');
            $table->string('city', 100)->nullable()->comment('市');
            $table->string('district', 100)->nullable()->comment('区');
            $table->string('detail', 255)->nullable()->comment('街道');
            $table->boolean('status')->default(1)->comment('状态，1 正常，0 禁用');
            $table->boolean('del_flag')->default(0)->comment('删除状态，1 删除，0 未删除');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('suppliers');
    }
}
